<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

class CreateReceivePaymentHeadersTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create("receive_payment_headers", function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->string('DocCode', 50)->nullable();
            $table->string('printnum', 50)->nullable();
            $table->string('refcode', 50)->nullable();
            $table->date('DocDate')->nullable();
            $table->string('Doctype', 50)->nullable();
            $table->string('periodid', 50)->nullable();
            $table->string('FormID', 50)->nullable();
            $table->string('cashcode', 50)->nullable();
            $table->string('cashName', 50)->nullable();
            $table->string('bankcode', 50)->nullable();
            $table->string('HDText', 50)->nullable();
            $table->decimal('summoney',10, 2)->nullable();
            $table->decimal('natsummoney', 10, 2)->nullable();
            $table->string('DocStatus', 50)->nullable();
            $table->string('EnterName', 50)->nullable();
            $table->date('EnterDate')->nullable();
            $table->string('ModifyName', 50)->nullable();
            $table->date('ModifyDate')->nullable();
            $table->string('PostName', 50)->nullable();
            $table->date('PostDate')->nullable();
            $table->string('ObjType', 50)->nullable();
            $table->string('companyid', 50)->nullable();
            $table->string('companyname', 50)->nullable();
            $table->string('companyid2', 50)->nullable();
            $table->string('companyname2', 50)->nullable();
            $table->string('cashcode2', 50)->nullable();
            $table->string('cashname2', 50)->nullable();
            $table->string('bankcode2', 50)->nullable();
            $table->string('CancelFlag', 50)->nullable();
            $table->string('blclosed', 50)->nullable();
            $table->string('ClearDocCode', 50)->nullable();
            $table->string('paymethod', 50)->nullable();
            $table->string('deptcode', 50)->nullable();
            $table->string('deptname', 50)->nullable();
            $table->string('orgid', 50)->nullable();
            $table->string('orgname', 50)->nullable();
            $table->string('oppocompanyid', 50)->nullable();
            $table->string('oppocompanyname', 50)->nullable();
            $table->string('refformid', 50)->nullable();
            $table->string('CheckCode', 50)->nullable();
            $table->string('docword', 50)->nullable();
            $table->string('sdgroup', 50)->nullable();
            $table->string('sdgroupname', 50)->nullable();
            $table->string('linkformid', 50)->nullable();
            $table->string('cltbrand', 50)->nullable();
            $table->string('ObjItem', 50)->nullable();
            $table->string('linkcode', 50)->nullable();
            $table->string('olddoccode', 50)->nullable();
            $table->string('cashtypeid', 50)->nullable();
            $table->string('cashtypename', 50)->nullable();
            $table->string('regage', 50)->nullable();
            $table->string('lastprintformid', 50)->nullable();
            $table->string('lastprintdocstatus', 50)->nullable();
            $table->string('lastprintnum', 50)->nullable();
            $table->string('hdcurrency', 50)->nullable();
            $table->string('hdexchange_rate', 50)->nullable();
            $table->decimal('hdamount', 10, 2)->nullable();
            $table->decimal('hdnatamount', 10, 2)->nullable();
            $table->string('AccountLinkCode', 50)->nullable();
            $table->string('ReimburseCode', 50)->nullable();
            $table->string('ContractLinkCode', 50)->nullable();
            $table->string('ReimburseName', 50)->nullable();
            $table->string('CautionerCode', 50)->nullable();
            $table->string('CautionerName', 50)->nullable();
            $table->string('Cashier', 50)->nullable();
            $table->string('Checker', 50)->nullable();
            $table->string('HDmemo', 50)->nullable();
            $table->string('Checkflag', 50)->nullable();
            $table->string('LinkDoccode', 50)->nullable();
            $table->string('LinkType', 50)->nullable();
            $table->string('CreateFlag', 50)->nullable();
            $table->decimal('FTmoney', 10, 2)->nullable();
            $table->string('FTcode', 50)->nullable();
            $table->string('watercode', 50)->nullable();
            $table->string('remitter', 50)->nullable();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('receive_payment_headers');
    }
}
